package classfile

type ConstantModuleInfo struct {
	cp         ConstantPool
	name_index uint16
}

func (self *ConstantModuleInfo) readInfo(reader *ClassReader) {
	self.name_index = reader.readUint16()
}
func (self *ConstantModuleInfo) ModuleName() string {
	return self.cp.getUtf8(self.name_index)
}

type ConstantPackageInfo struct {
	cp         ConstantPool
	name_index uint16
}

func (self *ConstantPackageInfo) readInfo(reader *ClassReader) {
	self.name_index = reader.readUint16()
}
func (self *ConstantPackageInfo) PackageName() string {
	return self.cp.getUtf8(self.name_index)
}
